package com.yoo.ons.adapter

import com.yoo.ons.base.adpater.BaseRecyclerAdapter
import com.yoo.ons.databinding.ItemPremiumSubscriptionsBinding
import com.yoo.ons.model.PremiumSubscriptionsModel
import com.yoo.ons.util.loadThumbnails

class PremiumSubscriptionsAdapter:BaseRecyclerAdapter<PremiumSubscriptionsModel,ItemPremiumSubscriptionsBinding>(ItemPremiumSubscriptionsBinding::inflate){
    override fun onBindView(
        holder: VH<ItemPremiumSubscriptionsBinding>,
        position: Int,
        item: PremiumSubscriptionsModel?
    ) {
        item?.apply {
            holder.binding.itemLogo.loadThumbnails(item.icon,holder.binding.itemLogo.width)
            holder.binding.itemTitle.text = item.tip
            holder.binding.itemContent.text = item.content
        }
    }

}
